Skip to content

Latest commit

 

History

History
52 lines (46 loc) · 2.27 KB

60 - Setup Linux VM on Digitalocean.md

File metadata and controls

52 lines (46 loc) · 2.27 KB
title date slug publish tags
60 - Setup Linux VM on Digitalocean
2023-07-11
100daysofcode-r3-60-setup-linux-vm-on-digitalocean
true

Livestream

<iframe width="100%" style="aspect-ratio: 16 / 9;" src="https://www.youtube.com/embed/1HN6Sh4Shvg" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>

Chose Ubuntu 22.10 with 2GB Ram & 2 AMD CPUs as it can be scaled up later, and upgrade to newer OS if needed

Components

Here are what I planned to install to this machine

  • Setup non-root user
    adduser narze
    usermod -aG sudo narze
    • Copy ssh key from root to user ref
    rsync --archive --chown=narze:narze ~/.ssh /home/narze
  • Docker, maybe Kubernetes cluster (k3s or k0s or microk8s or whatever people use in 2023)
    • Chose microk8s since it's from Canonical (Ubuntu)
      • See comparison
      • MicroK8s pronounced "Micro-Kates"
      sudo snap install microk8s --classic
      sudo usermod -a -G microk8s narze # add narze to microk8s user group
      newgrp microk8s # reload user group
      microk8s status --wait-ready # check status
      microk8s kubectl get all --all-namespaces # verify
      microk8s dashboard-proxy # dashboard
      microk8s start # or stop
  • Tailscale so that I can connect to it without remembering the IP?
    • curl -fsSL https://tailscale.com/install.sh | sh
    • Setup ssh alias and add it to my dotfiles
  • Setup my dotfiles
    • Generate & add id_ed25519.pub to Github
  • VSCode remote
  • Firewall
  • Github CLI https://github.com/cli/cli/blob/trunk/docs/install_linux.md